<?php


namespace app\admin\validate;

class ProjectsLayoutDrawings extends Base
{
    protected $rule =   [
        'id'  => 'require',
        'ids'  => 'require',
        'name'  => 'require',
        'thickness'  => 'require',
        'weight' => 'require',
        'material' => 'require',
        'size' => 'require',
        'utilization_rate' => 'require',
        'status' => 'require',
    ];

    protected $message  =   [
        'id.require' => 'id必须',
        'ids.require' => 'ids必须',
        'name.require' => '名称必须',
        'thickness.require' => '厚度必须',
        'weight.require' => '重量必须',
        'material.require' => '数量必须',
        'size.require' => '材料必须',
        'utilization_rate.require' => '尺寸必须',
        'status.require' => '状态必须',
    ];


    protected $scene = [
        'insert'  =>  ['name','thickness','weight','material','size','utilization_rate','status'],
        'update'  =>  ['id','name','thickness','weight','material','size','utilization_rate','status'],
        'detail'  =>  ['id'],
        'status'  =>  ['ids', 'status'],
        'del'  =>  ['ids'],
        'clean'  =>  ['ids'],
    ];
}